/**
 * ajax 服务路由集合
 */
 const router = require('koa-router')({
 	prefix: '/api'
 })
 const controllers = require('../controllers')

 for(let i in controllers){
 	if (i != 'index') {
 		router[controllers[i].type](`/${i}`, controllers[i].methods)
 	}
 }

 module.exports = router
